import { Link, useNavigate } from 'react-router-dom'

const Login = () => {
  const navigate = useNavigate()
  return (
    <div>
      我是登录页面
      <Link to="/article">声明导航,跳转到文章页面</Link> <br />
      <button onClick={() => navigate('/article')}>编程导航,跳转到文章页面</button> <br />
      <button onClick={() => navigate('/article?id=001&name=jack')}>searchParams传参,编程导航,跳转到文章页面</button> <br />
      <button onClick={() => navigate('/article/1001/jack222')}>params传参,编程导航,跳转到文章页面</button> <br />
    </div>
    
  )
}

export default Login